package model.surface;

/**
 * Class used to load scale factors for the path points.
 * The scale factors are parsed from JSON file.
 * 
 * @author EvilTeam
 *
 */
public class PathPointLoader {

	private static final int MAX_NUM_FOR_DIRECTION = 3;
	private static final int MIN_NUM_FOR_DIRECTION = -1;
	private float xPoint;
	private float yPoint;
	private int direction;

	public PathPointLoader(float xPoint, float yPoint, int direction) {
		this.setxPoint(xPoint);
		this.setyPoint(yPoint);
		this.setDirection(direction);
	}

	public float getxPoint() {
		return xPoint;
	}

	public void setxPoint(float xPoint) {
		if (xPoint >= 0)
			this.xPoint = xPoint;
	}

	public float getyPoint() {
		return yPoint;
	}

	public void setyPoint(float yPoint) {
		if (yPoint >= 0)
			this.yPoint = yPoint;
	}

	public int getDirection() {
		return direction;
	}

	public void setDirection(int direction) {
		if (direction >= MIN_NUM_FOR_DIRECTION
				&& direction <= MAX_NUM_FOR_DIRECTION)
		this.direction = direction;
	}
}
